<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <link rel="stylesheet" href="css/reset.css">
        <link rel="stylesheet" href="css/public.css">
        <link rel="stylesheet" href="__TPL__/css/register.css">
        <hdjs/>
       
    </head>
    <body style = "background-color:#F2F2F2;">
    	<div id="reg_top">
    		<div class="logo">
    			<img src="image/mclogo.png" alt="" class="mT20">
    		</div>
    	</div>
    	<div id="body">
    		<div class="title">
    			<p class="t mT20 mL20">橙 子 账 号 注 册</p>
    			<p class="c">小米帐户能使用小米手机、米聊、MIUI和小米的其他服务。如果您已拥有小米帐户，则可<a href="{|U:'Index/Login/index'}"> 在此登录</a></p>
    		</div>
    		<form action="{|U:'Index/Register/reg'}" method="post">
	    		<table>
	    			<tr>
	    				<th class="w100">用户名：</th>
	    				<td><input type="text" name="uname" id=""></td>
	    			</tr>
	    			<tr>
	    				<th>设置密码：</th>
	    				<td><input type="password" name="password" id=""></td>
	    			</tr>
	    			<tr>
	    				<th>确认密码：</th>
	    				<td><input type="password" name="repsd" id=""></td>
	    			</tr>
	    			<!-- <tr>
	    				<th>验证码：</th>
	    				<td>
	    					<input type="text" name="code" id="" class="w50">
	    					<img src="{|U:'Index/Register/code'}" alt="">
	    				</td>
	    			</tr> -->
	    		</table>
                <script>
                    $(function () {
                        $("form").validate({
                            uname: {
                                rule: {
                                    required: true,
                                    ajax:"check_uname"
                                },
                                error: {
                                    required: "用户名不能为空 ",
                                    ajax: " 用户名已经存在 "
                                },
                                message: " 请输入用户名 ",
                                success: " 用户名可用 "
                             },
                             password: {
                                rule: {
                                    required: true,
                                },
                                error: {
                                    required: "密码不能为空 ",
                                  
                                },
                                message: " 请输入密码 ",
                             },
                             repsd: {
                                rule: {
                                    confirm: "password"
                                },
                                error: {
                                    confirm: " 确认密码输入错误 "
                                },
                                 message: " 请再次输入密码 ",
                            },
                            // 验证规则
                            // code: {
                            //     rule: {
                            //     required: true,
                            //     ajax: "check_code"
                            //     },
                            //     error: {
                            //     required: " 验证码不能为空 ",
                            //     ajax: " 验证码输入错误 "
                            //     },
                            //     message: " 请输入验证码 ",
                            //     success: " 输入正确 "
                            //  }
                        })
                    })
                </script>
	    		<input type="submit" class="submit" value="立即注册">
	    	</form>
    	</div>
    </body>
</html>